{include file="../include.tpl"}
<!-- production -->
<script type="text/javascript" src="js/plupload.full.min.js"></script>
<!-- debug 
<script type="text/javascript" src="../js/moxie.js"></script>
<script type="text/javascript" src="../js/plupload.dev.js"></script>
-->
<script type="text/javascript" src="js/upload.js"></script>
<body>
{literal}
<style>
 
#ulDir{list-style:none; padding:0; margin:0;width:160px; height:100%;}
#ulDir li{width:160px; cursor:pointer; line-height:30px; padding-left:4px;}
#ulDir li input{display:none;}
#ulDir li div{ overflow:hidden;text-overflow:ellipsis; white-space:nowrap;}
#ulList{list-style:none; padding:0; margin:0;width:100%; padding-left:13px; height:500px;}
#ulList li{float:left;width:130px;height:140px;position: relative;}
#ulList li img{width:100px;height:90px; cursor:pointer;}
#ulList li div{position:absolute; top:100px;left:5px;}
#ulList li input{position:absolute; top:70px;left:0px;}
#filelist {list-style:none; margin:0; padding:0;border-top:1px solid #CCC;padding:10px 0px 10px 0px; display:none;}
#filelist div{height:10px; line-height:10px;}
#filelist li{height:45px;border-bottom: 1px solid #CCC; padding-top:5px;}
#tblDetail{display:none;}
#toolbar button{margin-left:10px;}
#tdShowImg p{color:#000}
.mnuRef{ position:absolute;z-index:100; left:128px; background-color:#ffffff; border:1px solid #BFBFBF;width:300px; height:100px; overflow:auto; display:none;}
.mnuRef ul{list-style:none; padding:0; margin:0;}
.mnuRef ul li{width:98%; height:30px; line-height:30px; text-align:left; padding-left:2px;}
.mnuRef ul li:hover{background-color:#EEE; cursor:pointer;} 
#filelist1 {list-style:none; margin:0; padding:0;border-top:1px solid #CCC;padding:10px 0px 10px 0px; display:none;}
#filelist1 div{height:10px; line-height:10px;}
#filelist1 li{height:45px;border-bottom: 1px solid #CCC; padding-top:5px;}
#tblDirGroup{width:100%}
#tblDirGroup td{border-bottom: dotted 1px #666; font-size:10px; padding-left:8px; line-height:15px;}

</style>

{/literal}
<iframe name="iframeSubmit" id="iframeSubmit" src="about:blank" style="display:none;"></iframe>
<div id="dialog-form-add-subject" title="增加主题" deftitle="增加主题" style="display:none;">
	<form name="formGame" id="formGame" method="post" action="?act={$act}&op=ajaxSaveType" enctype="multipart/form-data" target="iframeSubmit">
 
        <table height="280px" width="100%">
        
<tr><td height="1" valign="top">
<ul id="filelist1">
</ul>
</td></tr>
<tr><td>
<table cellpadding="0" cellspacing="0" width="100%" height="100%">
<tr><td align="center" valign="middle"><div style="width:200px;height:200px; background-color:#CCC"><button id="pickfiles1" style="margin-top:80px;">选择主题封面图片</button><img id="imgUpload" src="about:blank" style="display:none; margin-top:-100px;" width="200" height="200"/></div></td></tr>
<tr><td align="center" height="50">
主题名称：<input type="text" id="txtGroupName" style="width:300px;"/>
	<div id="idSubjectTips" class="mnuRef">
    <ul id="ulSubjectTips">
 
    </ul>
    </div>
</td></tr>
<tr><td align="center" height="50"><div id="btnSubjectModify1"style="cursor:pointer;display:none;" onClick="showSubjectDetail(1);">修改主题分类</div></td></tr>
<tr><td align="center" height="50" style="display:none;"><div id="btnSubjectModify"style="cursor:pointer;display:none;" onClick="showSubjectDetail(0);">批量修改主题下所有文件的信息包括主题信息</div></td></tr></table>
</td></tr>
  <tr><td><pre id="console"></pre></td></tr>
 
       </table>
 
	<input type="hidden" id="tid" name="tid" value="{$curTypeId}"/>
	<input type="hidden" id="editId" name="editId" value=""/>
	</form>
</div>
<div id="dialog-confirm" title="正在处理中..." style="display:none;">
      <table height="80" width="100%">
       <tr>
         <td style="width:100px;height:30px;" id="msg">正在处理...请勿关闭</td> </tr>
       </table>
</div>
<div id="dialog-form-adddir" title="添加目录" style="display:none;">
	
	<fieldset>
      <table height="90" width="100%">
                 <tr><td width="50">品牌</td><td><select id="brand" did="1" sel="{$f.brandId}" name="dbbrandId"></select></td></tr>
                 <tr><td>产品</td><td><select id="car" name="dbcarId" sel="{$f.carId}"></select></td></tr>
                 <tr><td>类型</td><td><select id="type" did="14" name="dbtypeId" sel="{$f.typeId}"></select></td></tr>
                 <tr><td>分类</td><td><select id="style" did="17" name="dbstyleId" sel="{$f.styleId}"></select></td></tr>
 
       </table>
	</fieldset>

</div>
<div id="dialog-form-dir" title="目录管理" style="display:none;">
	<form name="formGame" id="formGame" method="post" action="?act={$act}&op=ajaxSaveType" enctype="multipart/form-data" target="iframeSubmit">
	<fieldset>
      <table height="80" width="100%">
       <tr>
         <td style="width:100px;height:30px;">目录名称：<input type="text" id="dirName"/></td> </tr>
       </table>
	</fieldset>
	<input type="hidden" id="dirId" value="0"/>
	</form>
</div>
<div id="dialog-form" title="素材上传" style="display:none;">
	<form name="formGame" id="formGame" method="post" action="?act={$act}&op=ajaxSaveType" enctype="multipart/form-data" target="iframeSubmit">
 
        <table height="280px" width="100%">
       <tr>
         <td style="height:30px;"> <button id="pickfiles">选择上传文件</button> 
   
</td> </tr>
<tr><td height="250" valign="top">
<ul id="filelist">

</ul>
</td></tr>
  <tr><td><pre id="console"></pre></td></tr>
 
       </table>
 
	<input type="hidden" id="tid" name="tid" value="{$curTypeId}"/>
	<input type="hidden" id="editId" name="editId" value=""/>
	</form>
</div>
<div style="display:none" id="divTempFileHtml">
<table width="100%" class="tblFile" id="TBLID"><tr><td width="55" rowspan="2" align="right" style="padding-right:10px;display:none;"><img src="images/ico/tifs.png" height="30"/></td><td width="300">NAME</td><td >SIZE</td><td  rowspan="2" width="55" align="center"><div id="uploadRate"></div><img src="images/ok.gif" id="imgOk" style="display:none;"/></td></tr><tr><td colspan="2"><div id="progressbar"></div></td></tr></table>
</div>
{include file='header.tpl'}
<table id="tblData" width="1000" border="0" style="margin:auto;" cellpadding="0" cellspacing="0">
  
  <tr>
    
    <td valign="top"><table width="100%" height="138" border="0" cellpadding="0" cellspacing="0">
      <tr>
        <td height="13" valign="top">&nbsp;</td>
      </tr>
      <tr>
        <td valign="top"><table width="100%" height="600" border="0" align="center" cellpadding="0" cellspacing="0">
 
          <tr>

            <td>
            <table width="100%" height="100%">
            <tr>
            <td width="200px" valign="top" align="left" style="border:1px #CCC solid;">
           <table id="tblDir">
           <tr><td height="43" width="30">&nbsp;目录</td><td width="30"><input type="checkbox" id="chkDirAll" style="display:none;"/></td><td width="55"><button id="dirAdd">新建</button></td><td align="right"><button id="dirRename">重命名</button></td></tr>
           <tr><td colspan="5">
           <input type="text" style="width:186px; color:#CCC;" id="txtDirSer" value="输入关键词搜索目录" default="输入关键词搜索目录"/>
           </td></tr>
           <tr><td colspan="4" height="490" valign="top">
           <div style="height:490px; overflow:auto;">
            <ul id="ulDir">
 
            </ul>
           </div>  
           </td></tr>
           <tr><td id="dirPageNav" height="30" colspan="3"></td><td align="right"><button id="dirDel" >删除</button></td></tr>
           </table>
           </td><td>
 
	
	<table id="users" width="100%" height="100%" style="border:1px #CCC solid;">
		<tbody>
        <tr><td id="title" style="padding-left:13px; height:40px;" colspan="3">全部目录</td><a target="_blank" href="/pdf/内容厨房流程.pdf" style="color:#597DDB;padding-left:688px;">上传素材说明文档</a></tr>
 <tr>
        <td style="padding-left:13px; width:275px;"><select id="selSt" style="width:120px;">
        <option value="0">未完善信息</option>
        <option value="3">已完善信息</option>
        <!--
        <option value="4">待提交审批</option>
        <option value="5">已提交审批</option>
        -->
        <option value="1">已发布</option>
        <option value="2">已下架</option>
        </select>&nbsp;&nbsp;&nbsp;总计：<span id="total">0</span>&nbsp;&nbsp;&nbsp;<input type="checkbox" id="chkSelAll"/>全选</td>
        <td style="text-align:right; padding-right:10px;" id="toolbar" colspan="2"><button id="btnAddFengMian">1.新建主题</button><button id="createUser">2.素材上传</button><button id="btnSetDir" style="display:none;">批量归目录</button><button id="btnRemoveDir" style="display:none;">批量移除文件</button><button id="btnModify" style="display:none;">批量修改</button><button id="btnPost">3.完善备注</button><button id="btnAddApply">4.加入申请</button><button id="btnUnPost" >5.批量下架</button></td></tr>
         <tr>
              <td align="left" valign="top" colspan="3" height="500">
              <ul id="ulList">

              </ul>
              </td>
         </tr>
         <tr><td colspan="2"><div id="divPageNav" style="position:inherit;width:100%;">{$pageNav}</div></td><td align="right"><button id="btnDelete">删除</button></td></tr>
		</tbody>
	</table>
 
            </td>
            </tr>
            </table>
 </td>
          </tr>
        </table>
          </td>
      </tr>
    </table></td>
     
  </tr>
   <tr>
        <td  colspan="3" height="30" valign="middle">
     
    </td>
  </tr>
  <tr>
    <td  valign="middle">
     {include file='footer.tpl'} 
    </td>
  </tr>
</table>

<table id="tblDetail" width="1000" style="margin:auto;" border="0" cellpadding="0" cellspacing="0">
   
  <tr>
    
    <td valign="top" ><table width="100%" height="138" border="0" cellpadding="0" cellspacing="0">
      
      <tr>
        <td valign="top"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
 
          <tr>
            <td>
            <div id="users-contain" class="ui-widget" style="width:100%;">
	<form id="form" action="?act={$act}&op=saveInfo" method="post" target="iframeSubmit">
	<table id="users" class="ui-widget ui-widget-content">
		<tbody>
         <tr>
              <td align="left" valign="top" width="600">
                 <table width="100%">
                 <tr><td id="tdShowImg" colspan="2" height="450" align="center" style="text-align:center; font-size:20px; color:#ffffff; font-weight:bold;" valign="middle"><button id="btnUploadPrevPic">上传预览图片</button><p></p>
                 </td></tr>
                 <tr><td width="270">文件编号：<span id="idid">{$f.fid}</span></td><td>上传者：<span id="uploader" style="margin-left:13px;"></span></td></tr>
                 <tr><td>文件名称：<input id="mark" type="text" name="dbmark" value="{$f.mark}" size="30" style="margin-left:1px;width:200px;"/></td>
                 <td>作者：<input id="author" type="text" name="dbauthor" value="{$f.author}" size="30" style="margin-left:25px;width:200px;"/></td>
                 </tr>
<tr><td>创建时间：<select id="year" sel="0" style="width:56px;"></select>&nbsp;年&nbsp;<select id="month" sel="0" style="width:56px;">
<option value="0">选择</option>
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
<option value="6">6</option>
<option value="7">7</option>
<option value="8">8</option>
<option value="9">9</option>
<option value="10">10</option>
<option value="11">11</option>
<option value="12">12</option>
</select>&nbsp;月<input type="hidden" id="hidyear" name="dbyear" /></td><td>有效期限：<input type="text" name="dbavaliDate" id="avaliDate" value="{$f.avaliDate}" style="margin-left:2px;width:200px;"/></td></tr>
                 <tr>
                <td valign="top">
                <div style="width:61px; float:left">出处说明：</div>
<textarea  id="instro" name="dbinstro" style="width:200px;"></textarea>
               </td><td><div style="width:61px; float:left">使用限制：</div><textarea  name="dblimitUse" id="limitUse" style="width:200px;"></textarea></td></tr>
  
                 
                 </table> 
              </td>
              <td align="left" valign="top">
 				<table width="100%" class="tblright">
                 <tr><td><button id="btnDetailSave" style="height:40px;width:333px; font-size:15px;">保存信息</button></td></tr>
                 <tr><td><button id="btnDetailPost" style="height:40px;width:300px;font-size:15px; display:none;">保存并发布</button></td></tr>
                 <tr><td><button id="btnDetailUnPost" style="height:40px;width:333px;font-size:15px;">下架</button></td></tr>
                 <tr><td align="left" valign="top" style="padding:0; border:none;">
                 <table width="100%" cellpadding="0" cellspacing="0" style="margin:0;">
                 <tr><td style="background-color:#EEE">添加目录</td><td style="background-color:#EEE"><button id="btnShowDirForm" style="float:right;">添加</button></td></tr>
                 <tr><td colspan="2" style="padding:0; border:none;">
                 <br/>
                 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#00F" id="dirCars">—品牌车型&nbsp;(0)</span>
                 <table id="tblSelCar"></table>
                 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#00F" id="dirTypes">—内容类型&nbsp;(0)</span>
                 <table id="tblSelType"></table>
                 </td></tr>
 
                 </table>
                 </td></tr>
                 <tr><td style="padding:0; border:none;">
                 <table width="100%" cellpadding="0" cellspacing="0" style="margin-top:10px; margin-bottom:0">
                 <tr><td style="background-color:#EEE">设置关键词</td></tr>
                 <tr><td>
                 <textarea id="keywords" name="dbkeywords" rows="3" style="width:325px;">{$f.keywords}</textarea>
                 </td></tr>
                 
                 </table>
                 </td></tr>
                 <tr><td style="padding:0; border:none;"><table width="100%" cellpadding="0" cellspacing="0" style="margin-top:10px; margin-bottom:0">
                 <tr><td style="background-color:#EEE">设置专题</td></tr>
                 <tr><td>
                 <textarea id="zhuanTi" name="dbzhuanTi" rows="3" style="width:325px;">{$f.zhuanTi}</textarea>
                 </td></tr>
                 
                 </table></td></tr>
				 <input type="hidden" id="pdid" name="pdid" value="0"/>
                 <input type="hidden" id="sid" name="dbsid" value="0"/>
                 <input type="hidden" id="isUpdateAll" name="isUpdateAll" value="0"/>
                 <input type="hidden" id="id" name="id" value="{$f.id}"/>
                 <input type="hidden" id="optype" name="optype" value=""/>
                 <input type="hidden" id="carIds" name="dbcarIds"/>
                 <input type="hidden" id="typeIds" name="dbtypeIds"/>
                 <input type="hidden" id="carNames" name="dbcarNames"/>
                 <input type="hidden" id="typeNames" name="dbtypeNames"/>
                 </table> 
              </td>
         </tr>
		</tbody>
	</table>
    </form>
    <input type="hidden" id="act" value="{$act}"/>
</div>
 </td>
          </tr>
        </table>
          </td>
      </tr>
    </table></td>
    <input type="hidden" id="roleId" value="{$roleId}"/>
  </tr>
     <tr>
        <td  height="30" valign="middle">
     
    </td>
  </tr>  <tr>
    <td valign="middle">

    </td>
  </tr>
</table>
</body>
<script type="text/javascript" src="js/groupupload.js"></script>
